#include <stdio.h>
int change1(int* a, int* b);
int change2(int* a, int* b);
int change3(int* a, int* b);
void echo(int a, int b);
int main(int argc, char argv[])
{
	int a = 100;
	int b = 1000;
	echo(a, b);
	change1(&a, &b);
	echo(a, b);
	change2(&a, &b);
	echo(a, b);
	change3(&a, &b);
	echo(a, b);
	change4(&a, &b);
	echo(a, b);
	return 0;
}
void echo(int a, int b)
{
	printf("A = %d, B= %d\n",a, b);
}

int change1(int* a, int* b)
{
	*a = *a + *b - (*b = *a);
	return 0;
}

int change2(int* a, int* b)
{
	*a = *a + *b;
	*b = *a - *b;
	*a = *a - *b;
	return 0;
}

int change3(int* a, int* b)
{
	*a = *a * *b;
	*b = *a / *b;
	*a = *a / *b;
	return 0;
}

int change4(int* a, int* b)
{
	*a = *a^*b;
	*b = *a^*b;
	*a = *a^*b;
	return 0;
}
 
